import {BrowserModule} from '@angular/platform-browser';
import {NgModule} from '@angular/core';
import {FormsModule, ReactiveFormsModule} from '@angular/forms';

import {AppComponent} from './app.component';
import {HerosComponent} from './heros/heros.component';
import {HeroDetailComponent} from './hero-detail/hero-detail.component';
import {MessagesComponent} from './messages/messages.component';
import {HttpClientModule} from '@angular/common/http';
import {HttpClientInMemoryWebApiModule} from 'angular-in-memory-web-api';
import {InMemoryDataService} from './services/in-memory-data.service';


import {HeroService} from './services/hero.service';
import {AppRoutingModule} from './app-routing.module';
import {DashboardComponent} from './dashboard/dashboard.component';
import {HeroSearchComponent} from './hero-search/hero-search.component';
import {DashboardModule} from './dashboard/dashboard.module';
import {HeroSearchModule} from './hero-search/hero-search.module';
import {JobAdComponent} from './ad-banner/job-ad/job-ad.component';
import {AdDirective} from './ad-banner/job-ad/ad.directive';
import {AdBannerComponent} from './ad-banner/ad-banner.component';
import {HeroProfileComponent} from './ad-banner/hero-profile/hero-profile.component';
import {HighlightDirective} from './directives/highlight.directive';
import {UnlessDirective} from './directives/unless.directive';
import { ExsponentialStrengthPipe } from './pipes/exsponential-strength.pipe';
import { FormComponent } from './form/form.component';
import { Form2Component } from './form2/form2.component';
import { ForbiddenValidatorDirective } from './directives/forbidden-validator.directive';

// import { AppRoutingModule } from './app-routing/app-routing.module'


@NgModule({
  // declaration @Component
  declarations: [
    AppComponent,
    HerosComponent,
    HeroDetailComponent,
    MessagesComponent,
    DashboardComponent,
    HeroSearchComponent,
    JobAdComponent,
    AdDirective,
    AdBannerComponent,
    HeroProfileComponent,
    HighlightDirective,
    UnlessDirective,
    ExsponentialStrengthPipe,
    FormComponent,
    Form2Component,
    ForbiddenValidatorDirective

  ],
  // import @NgModule
  imports: [
    AppRoutingModule,
    BrowserModule,
    FormsModule,
    ReactiveFormsModule,
    HttpClientModule,
    // HeroSearchModule,
    // DashboardModule,
    HttpClientInMemoryWebApiModule.forRoot(
      InMemoryDataService, {dataEncapsulation: false}
    ),
  ],
  entryComponents: [
    JobAdComponent,
    HeroProfileComponent,
  ],
  // providers @Injectable
  providers: [
    // HeroService
  ],
  bootstrap: [AppComponent]
})
export class AppModule {
}
